/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package elementsDefense.towers;

import com.jme3.asset.AssetManager;
import com.jme3.math.Vector3f;
import com.jme3.scene.Node;
import com.jme3.scene.Spatial;
import elementsDefense.EBus;
import elementsDefense.Main;
import elementsDefense.enemies.BasicEnemy;

/**
 *
 * @author Ricardo
 */
public abstract class Tower {
    AssetManager assetManager;

    public void build(AssetManager assetManager, Node node, Vector3f location){
        this.assetManager = assetManager;
        this.node =node;
        this.location = location;
        
        Main.player.addGold(-getCost());
    }

    abstract void fire(BasicEnemy enemy);
    public Vector3f fireLocation;
    Spatial geom;
    public Vector3f location;
    Node node;

    abstract void prepareToFire(BasicEnemy enemy, float animPhase);
    abstract int getCost();
    SearchAndDestroyControl searchAndDestroy;
    
}
